Skip to content

feat(navigation): gate editor activation capabilities - #400

Closed
dubesinhower wants to merge 16 commits into
mixelpixx:mainfrom
dubesinhower:feat/verified-editor-activation
Closed

feat(navigation): gate editor activation capabilities#400
dubesinhower wants to merge 16 commits into
mixelpixx:mainfrom
dubesinhower:feat/verified-editor-activation

Conversation

@dubesinhower

Copy link
Copy Markdown
Contributor

Navigation MVP slice N5

Adds semantic, exact-context capability gates for document/sheet activation, object reveal/centering, and view fitting. On the bundled KiCad 10 protocol these operations return typed unsupported results and send no raw action.

Why this belongs in the MVP

Clients need an honest answer about activation and viewport behavior. Pretending that selection implies reveal, or routing through unstable action strings without active-context readback, would violate the Navigation MVP's safety contract.

Dependency

Behavior

  • Accepts an explicit project, saved document, editor, and canonical schematic instance path.
  • Resolves reveal/center object KIIIDs before any live request.
  • Proves the exact open document/sheet and reads the running KiCad version/capability matrix.
  • Reports activate_document, activate_sheet, reveal_object, center_object, or fit_view as typed unsupported_capability with the observed version when no stable command plus active-context readback exists.
  • Stale objects and wrong/closed document or sheet contexts fail before any action.
  • Sends only typed GetOpenDocuments and GetVersion probes; no RunAction, mouse, keyboard, or coordinate automation is exposed.

Intentionally unsupported

  • KiCad 10 exact activation, reveal, center, and fit cannot report success because the bundled stable protocol provides neither the command nor the required active-context readback.
  • A future version advertising a primitive still remains unsupported until Konnect has a version-gated semantic adapter and result-derived verification.

Verification

  • cargo fmt --all -- --check
  • cargo test -p konnect-core editor_navigation --lib — 15 passed
  • cargo test -p konnect-ipc --test mock_server_test — 47 passed, 1 ignored
  • cargo test -p konnect-core --lib — 946 passed, 9 ignored
  • cargo test --workspace --all-targets — passed (live/environment-only tests remained ignored)
  • cargo clippy --workspace --all-targets -- -D warnings
  • xtask fix-doc-counts --check — 21 toolsets, 226 registered, 233 total
  • git diff --check

Hermetic tests prove typed unsupported capability/version output, exact context probing, stale-object refusal before IPC, schematic activate_sheet classification, and the absence of any raw action request.

Remaining risks

  • No real KiCad endpoint was available, so no live-GUI activation is claimed.
  • Active editor/document/sheet state remains unobservable on the bundled KiCad 10 API and is never inferred from open-document order.
  • Public naming and compatibility remain subject to Design Priority 1 semantic editor navigation MVP #395.

@neusse

neusse commented Sep 7, 2026

Copy link
Copy Markdown
Collaborator

Accounting complete in #494. That focused replacement keeps the generally useful portion of this draft—separate center_object and fit_view capability fields plus hermetic unavailable-capability evidence—without publishing an activation tool whose only correct KiCad 10 behavior is refusal. Original @dubesinhower authorship is preserved. Closing this cumulative draft as directed in #395; #494 is the small reviewable successor before the final cross-probe slice.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

status:waiting-on-dependency Next actor: the dependency owner — see linked blocking issue

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants